/*----------------------------------------------------------------------------------------
*
*  Copyright 2019, Gao Hai Hui, <fromzeropoint@126.com>.  All rights reserved.
*  https://gitee.com/helloworldghh/xoskit.git
*  Use of this source code is governed by a MIT license
*  that can be found in the License file.
*
----------------------------------------------------------------------------------------*/
#ifndef __C15A8B67_7048_478f_B9AA_3A98645DE708__
#define __C15A8B67_7048_478f_B9AA_3A98645DE708__

#include "../tools/head.h"

/////////////////////////////////////////////////////////////////////////////////////////
// 

namespace xos_box
{
    // 
    // heart_acceptor
    // 
    class heart_acceptor : public xos_stl::mem_item< xos::release_impl< heart_acceptor >, thread_lock >,
        public xos::i_release
    {
    public:
        typedef xos::release_impl< heart_acceptor > T;

    public:
        //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
        // 
        static int get_xos_item_data( ITEM_DATA*& item_ptr );

    public:
        heart_acceptor();
        ~heart_acceptor();

    public:
        f_acceptor m_pAcceptor;
        int32_t m_iInterval;
        int32_t m_iCurTime;

    public:
        int init();
        int term();
    };
} // xos

#endif // __C15A8B67_7048_478f_B9AA_3A98645DE708__
